package com.baizhi.springboot.entity;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

public class Inform {
    /*`id` int(11) NOT NULL AUTO_INCREMENT,
  `title` varchar(255) DEFAULT NULL,
  `content` varchar(255) DEFAULT NULL,
  `startdate` date DEFAULT NULL,
  `enddate` date DEFAULT NULL,
  `sysdate` date DEFAULT NULL,
  `level` varchar(255) DEFAULT NULL,*/
    private Integer id;
    private String title;
    private String content;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date startdate;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date enddate;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date sysdate;
    private String level;

    @Override
    public String toString() {
        return "Inform{" +
                "id=" + id +
                ", title='" + title + '\'' +
                ", content='" + content + '\'' +
                ", startdate=" + startdate +
                ", enddate=" + enddate +
                ", sysdate=" + sysdate +
                ", level='" + level + '\'' +
                '}';
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public Date getStartdate() {
        return startdate;
    }

    public void setStartdate(Date startdate) {
        this.startdate = startdate;
    }

    public Date getEnddate() {
        return enddate;
    }

    public void setEnddate(Date enddate) {
        this.enddate = enddate;
    }

    public Date getSysdate() {
        return sysdate;
    }

    public void setSysdate(Date sysdate) {
        this.sysdate = sysdate;
    }

    public String getLevel() {
        return level;
    }

    public void setLevel(String level) {
        this.level = level;
    }

    public Inform(Integer id, String title, String content, Date startdate, Date enddate, Date sysdate, String level) {
        this.id = id;
        this.title = title;
        this.content = content;
        this.startdate = startdate;
        this.enddate = enddate;
        this.sysdate = sysdate;
        this.level = level;
    }

    public Inform() {
    }
}
